home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Overload Trio 2
/
Shareware Overload Trio Volume 2 (Chestnut CD-ROM).ISO
/
dir35
/
2xcopy.zip
/
START.BAT
< prev
next >
Wrap
DOS Batch File
|
1994-05-07
|
8KB
|
209 lines
@echo off
goto start
┌────────────
│ START.BAT █
▄▄▄▄▄▄▄▄▄▄▄▄█
Fri 05-06-1994 12:26:41
COMMAND: START
(no parameters)
Trying to make a smart though simple install program for Trakker
Version 4.03 and other programs that require installation from a
floppy drive to a known directory on C: Drive.
The sequence:
1. Use HELP.BAT to display a HELP.TXT file if you wish. If not
start program by typing START.BAT
2. START.BAT
displays a request to type in "A" or "B"
3. EDIT2.EXE accepts keyboard input to run batch file A.BAT or
B.BAT
4. A.BAT or B.BAT runs to change to A: or B: Drive then restarts
START.BAT
5. Makes C:\TRAKKER3 Directory if it doesn't exist
6. Use XCOPY.EXE to copy all files to that directory
7. Check IF ERRORLEVEL for success or failure
8. Save list of files copied successfully in FILE(S).TXT and
display that file list with READ.COM
John De Palma on CompuServe 76076,571
:start
if "%1"=="A" goto ADrive
if "%1"=="a" goto ADrive
if "%1"=="B" goto BDrive
if "%1"=="b" goto BDrive
if not "%2"=="" goto HelpText
cls
echo ╒══════════════════════════════════════════════════════════════════╕
echo │ INSTALL PROGRAM │
echo │ │
echo │ TRAKKER 4.03 │
echo │ │
echo │ 1. TYPE: This Drive letter (A or B) in the edit box │
echo │ 2. PRESS: {Enter} │
echo ╘══════════════════════════════════════════════════════════════════╛
echo
call edit2.exe
goto End
:ADrive
a:
if not exist c:\trakker3\nul md c:\trakker3
echo.
echo Working.....
echo.
echo Reading and Copying Files
echo ╔════════════════════════════════════════╗ > file(s).txt
echo ║ FILES COPIED TO C:\TRAKKER3 ARE: ║ >> file(s).txt
echo ╚════════════════════════════════════════╝ >> file(s).txt
rem make sure you put the trailing slash in the directory name
rem select the files you want copied by using wild cards ie:
rem use multiple command lines to copy these files
rem xcopy a:\*.exe
rem xcopy a:\*.txt
xcopy a:\*.* c:\trakker3\ >> file(s).txt
if errorlevel 5 if not errorlevel 6 goto ERROR5
if errorlevel 4 if not errorlevel 5 goto ERROR4
if errorlevel 3 if not errorlevel 4 goto ERROR3
if errorlevel 2 if not errorlevel 3 goto ERROR2
if errorlevel 1 if not errorlevel 2 goto ERROR1
if errorlevel 0 if not errorlevel 1 goto ERROR0
pause
:BDrive
b:
if not exist c:\trakker3\nul md c:\trakker3
echo.
echo Working.....
echo.
echo Reading and Copying Files
echo ╔════════════════════════════════════════╗ > file(s).txt
echo ║ FILES COPIED TO C:\TRAKKER3 ARE: ║ >> file(s).txt
echo ╚════════════════════════════════════════╝ >> file(s).txt
rem make sure you put the trailing slash in the directory name
rem select the files you want copied by using wild cards ie:
rem use multiple command lines to copy these files
rem xcopy b:\*.exe
rem xcopy b:\*.txt
xcopy b:\*.* c:\trakker3\ >> file(s).txt
if errorlevel 5 if not errorlevel 6 goto ERROR5
if errorlevel 4 if not errorlevel 5 goto ERROR4
if errorlevel 3 if not errorlevel 4 goto ERROR3
if errorlevel 2 if not errorlevel 3 goto ERROR2
if errorlevel 1 if not errorlevel 2 goto ERROR1
if errorlevel 0 if not errorlevel 1 goto ERROR0
pause
:ERROR5
echo
cls
echo.
echo ┌──────────────────────────────────────┐
echo │ ERROR #5 │
echo │ │
echo │ Disk is Write Protected │
echo │ │
echo │ CORRECT and try again │
echo │ │
echo └──────────────────────────────────────┘
echo.
pause
goto End
:ERROR4
echo
cls
echo.
echo ┌──────────────────────────────────────┐
echo │ ERROR #4 │
echo │ │
echo │ Multiple Causes; Invalid Drive │
echo │ Out of Memory; No disk space, etc │
echo │ CORRECT and try again │
echo │ │
echo └──────────────────────────────────────┘
echo.
pause
goto End
:ERROR3
echo
cls
echo.
echo ┌──────────────────────────────────────┐
echo │ ERROR #3 │
echo │ │
echo │ Undefined.... What's goin' on??? │
echo │ │
echo │ CORRECT and try again │
echo │ │
echo └──────────────────────────────────────┘
echo.
pause
goto End
:ERROR2
echo
cls
echo.
echo ┌──────────────────────────────────────┐
echo │ ERROR #2 │
echo │ │
echo │ User terminated XCOPY.EXE │
echo │ │
echo │ Ctrl + C pressed by user │
echo │ │
echo └──────────────────────────────────────┘
echo.
pause
goto End
:ERROR1
echo
cls
echo.
echo ┌──────────────────────────────────────┐
echo │ ERROR #1 │
echo │ │
echo │ No files found to copy │
echo │ │
echo │ CORRECT and try again │
echo │ │
echo └──────────────────────────────────────┘
echo.
pause
goto End
:ERROR0
echo
cls
echo.
echo ┌──────────────────────────────────────┐
echo │ SUCCESS!!! │
echo │ │
echo │ TRAKKER Files copied │
echo │ │
echo │ to C:\TRAKKER3 Directory │
echo │ │
echo │ Files Copied will now │
echo │ be listed │
echo └──────────────────────────────────────┘
echo.
pause
cls
read file(s).txt/n
goto End
:HelpText
read help.txt/n
start.bat
goto End
:End